﻿namespace Sgr.BillNumbering.Services
{
    public interface ICodeGenerationStrategy
    {
        /// <summary>
        /// 策略名称(唯一标识)
        /// </summary>
        string StrategyName { get; }

        /// <summary>
        /// 异步生成编码
        /// </summary>
        Task<string> GenerateAsync(CodeRule rule, ICodeSequence sequenceGenerator, string customPrefix = "", CancellationToken cancellationToken = default);
    }
}